from flask import Flask

from math import pi
class Shape:
    area=0
    def __init__(self,name):
        self.name=name
    def get_area(self):
        print("面积为%s"+self.area)
class Circle(Shape):
    def __init__(self,name,radius):
        self.radius=radius
        Shape.__init__(self,name)
    def get_area(self):
        self.area=self.radius**2*pi
        print("%s的面积为%s" % (self.name,self.area))
C=Circle('圆',2)
C.get_area()